#include "ToolBox/gl/ViewPoints/Projections/ortho.h"

Ortho::Ortho()
{
    left= 0;
    right=10;
    bottom=0;
    top=10;
    nearVal=0;
    farVal=1000;

    width=left+right;
    height=bottom+top;
}

Ortho::Ortho(GLdouble aLeft, GLdouble aRight, GLdouble aBottom, GLdouble aTop, GLdouble aNear, GLdouble aFar) :
    left(aLeft), right(aRight), bottom(aBottom), top(aTop), nearVal(aNear),farVal(aFar)
{
    width=left+right;
    height=bottom+top;
}

void Ortho::DefineProjection()
{
    glMatrixMode(GL_PROJECTION);
    glLoadIdentity();
    glOrtho(left,right,bottom,top,nearVal,farVal);
}
